<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
    <style>
        th,td{
            width: 200px;
        }
        .aa{
            color: red;
        }
        thead tr{
            background-image: linear-gradient(to top,red,orange);
        }
        tbody tr{
            background-image: linear-gradient(to left,skyblue,green);
        }
        tbody tr:hover{
            background-image: linear-gradient(to right,skyblue,yellow);
        }
    </style>
</head>
<body>
    <table border="1">
        <thead>
            <tr>
                <th>姓名</th>
                <th>身份</th>
                <th>资质</th>
            </tr>
        </thead>
        <tbody align="center">

        </tbody>
    </table>
</body>
</html>
<script>
    var arr=[
        {
            'xm':'古月方源',
            'xx':'蛊修',
            'zz':'丙等'
        },
        {
            'xm':'古月方正',
            'xx':'蛊修',
            'zz':'甲等'
        },
        {
            'xm':'白凝冰',
            'xx':'蛊修',
            'zz':'十绝天资'
        },
        {
            'xm':'小熊饼干',
            'xx':'蛊修',
            'zz':'乙等'
        }
    ]
        var tb=document.querySelector("tbody")
        for(i=0;i<arr.length;i++){
            var tr=document.createElement('tr')
            tr.innerHTML=`
                <td>${arr[i]['xm']}</td>
                <td>${arr[i]['xx']}</td>
                <td class='aa'>${arr[i]["zz"]}</td>
            `;
            tb.appendChild(tr)
        }
</script>